package com.neko.seed.util.redis;

import org.springframework.core.annotation.AliasFor;

import java.lang.annotation.*;

/**
 * Created by liuhangjun on 2017/9/7.
 */
@Target({ElementType.METHOD, ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Documented

public @interface CacheDuration {
    //Sets the expire time (in seconds).
    @AliasFor("value")
    long duration() default 60;

    /**
     * expire time, default 60s
     */
    @AliasFor("duration")
    long value() default 60;
}
